
'use strict';
const express=require('express');
const path=require('path');
const moment=require('moment');
const xtpl=require('xtpl');

const os=require('os');

const db=require(path.join(__dirname,"../configs/database.js"));
const base=require(path.join(__dirname,"./baseController.js"));

module.exports.systeme=(req,res)=>{

     const arch=os.arch();
     const hostname=os.hostname();
     const release=os.release();
     const totalmem=os.totalmem();
     const relea=os.release();
   

     let data={
 
           arch:arch,
           hostname:hostname,
           release:release,
           totalmem:totalmem,
           relea:relea,
     }

     console.log(data);
    


         xtpl.renderFile(
           path.join(__dirname,"../views/admin/sys.html"),
           {               
               sys:data

           },
           (err,content)=>{
               
             if(err){
             	return console.log(err);
             }
             	res.setHeader("Content-Type","text/html;charset=utf-8");
                res.end(content);
           }

         	);


}